home *** CD-ROM | disk | FTP | other *** search
- #
- # MAKEFILE
- # Application that uses the Data Objects Chapter 6
- #
- # Copyright (c)1993 Microsoft Corporation, All Rights Reserved
- #
- # Kraig Brockschmidt, Software Design Engineer
- # Microsoft Systems Developer Relations
- #
- # Internet : kraigb@microsoft.com
- # Compuserve: >INTERNET:kraigb@microsoft.com
- #
-
- #Add '#' to the next line for 'noisy' operation
- !CMDSWITCHES +s
-
- #
- #Compiler flags
- #Use "SET RETAIL=1" from MS-DOS to compile non-debug version.
- #
- !ifndef RETAIL
- CFLAGS = -c -nologo -Od -AS -Zipe -G2s -W3 -GA -GEs
- LINK = /al:16/ONERROR:NOEXE/CO
- DEFS = -DSTRICT -DDEBUG
- !else
- CFLAGS = -c -nologo -Oas -AS -Zpe -G2s -W3 -GA -GEs
- LINK = /al:16/ONERROR:NOEXE
- DEFS = -DSTRICT
- !endif
-
- .SUFFIXES: .h .obj .exe .cpp .res .rc
-
- TARGET = datauser
-
- goal: precomp.pch $(TARGET).exe
-
- clean:
- del *.pch
- del *.obj
- del *.res
- del *.exe
-
- PCHFLAGS= -Yu$(TARGET).h -Fpprecomp.pch
-
- LIBS = libw slibcew compobj ole2 storage
- INCLS = $(TARGET).h
- OBJS = $(TARGET).obj iadvsink.obj
- RCFILES = $(TARGET).ico
-
-
- #####
-
- .cpp.obj:
- echo ++++++++++
- echo Compiling $*.cpp
- cl $(CFLAGS) $(PCHFLAGS) $(DEFS) $*.cpp
-
- .rc.res:
- echo +++++++++
- echo Compiling Resources
- rc -r $(DEFS) $*.rc
-
- precomp.pch : $(TARGET).h
- echo +++++++++
- echo Precompiling $(TARGET).h
- cl $(CFLAGS) $(DEFS) -Yc$(TARGET).h -Fpprecomp.pch -Foprecomp precomp.cpp
-
-
-
- #This rule builds a linker response file on the fly depending on debug flags
- $(TARGET).exe : $(OBJS) $(TARGET).res $(TARGET).def
- echo ++++++++++
- echo Linking $@
- echo precomp.obj + > $(TARGET).lrf
- echo $(OBJS) >> $(TARGET).lrf
-
- echo $(TARGET).exe $(LINK) >> $(TARGET).lrf
- echo nul/li >> $(TARGET).lrf
- echo $(LIBS)/NOD/NOE >> $(TARGET).lrf
- echo $(TARGET).def >> $(TARGET).lrf
-
- link @$(TARGET).lrf
- rc -v $(TARGET).res $(TARGET).exe
- del $(TARGET).lrf
-
-
- ##### Dependencies #####
-
- $(TARGET).obj : $(TARGET).cpp $(INCLS)
- echo +++++++++
- echo Compiling $*.cpp
- cl -nologo $(CFLAGS) $(DEFS) $*.cpp
-
- iadvsink.obj : iadvsink.cpp $(INCLS)
- $(TARGET).res : $(TARGET).rc $(INCLS) $(RCFILES)
-